package com.qian.apiserver.entity;

import com.yaowk.service.common.GeneratorNote;
import com.yaowk.service.system.entity.SysUser;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.hibernate.annotations.ColumnDefault;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;
import java.util.Set;


@Getter
@Setter
@ToString
@DynamicInsert
@DynamicUpdate
@Entity
/**
 * 角色信息
 */
public class GmUser extends SysUser{
    @GeneratorNote("性别")
    private Byte sex;//0:保密 1:男 2:女
    @GeneratorNote("非绑定筹码")
    @ColumnDefault("0")
    private BigDecimal notBindChip;
    @GeneratorNote("绑定筹码")
    @ColumnDefault("0")
    private BigDecimal bindChip;
    @GeneratorNote("宝石")
    @ColumnDefault("0")
    private BigDecimal gemstone;
    @GeneratorNote("胜率")
    @ColumnDefault("0")
    private BigDecimal win;
    @GeneratorNote("总场次")
    @ColumnDefault("0")
    private Long count;
    @GeneratorNote("手机号")
    private String phone;

    @GeneratorNote("邀请人数")
    @ColumnDefault("0")
    private Integer spreadMany;
    @GeneratorNote("银行卡")
    private String bankCard;
    @GeneratorNote("持卡人")
    private String cardholder;
    @GeneratorNote("签到总天数")
    private Integer signDay;
    @GeneratorNote("最佳牌型")
    private String bestCard;
    @GeneratorNote("QQ")
    private String QQ;
    @GeneratorNote("微信")
    private String WX;
    @GeneratorNote("用户编号")
    @Column(unique = true)
    private Long userCode;
    @GeneratorNote("历史最高筹码")
    private Long countChip;
    @GeneratorNote("单月签到天数")
    private Integer signMonth;
    @GeneratorNote("连续签到天数")
    private Integer signContinuous;
    @OneToMany
    private Set<GmMatchRecord> matchRecords;
    @OneToMany
    private Set<GmWithdrawal> withdraawls;
    @OneToMany
    private Set<GmOrder> orders;
}
